package com.ee.bruscar;

import com.ee.bruscar.configuration.InterfaceConfiguration;
import com.ee.bruscar.configuration.hint.DataModelHint;
import com.ee.bruscar.configuration.hint.MemberHint;
import com.ee.bruscar.generator.ImplementorFactory;
import com.ee.bruscar.model.dto.Customer;
import com.ee.bruscar.service.CustomerService;
import com.ee.bruscar.service.CustomerServiceStub;
import com.ee.bruscar.service.CustomerServiceStubTarget;

/**
 * Hello world!
 *
 */
public class App 
{
    public static void main( String[] args )
    {
    	System.out.println(">>");
    	
    	String srcPath = "/Users/edeustace/dev/Dumpster/dumpster-poc/src/main/java";
    	String interfaceToImplement = CustomerService.class.getName();
    	String generatedName = CustomerService.class.getName() + "Stub";
    	InterfaceConfiguration config =
    			new InterfaceConfiguration( interfaceToImplement, generatedName,srcPath );
    	
    	DataModelHint dataHint = new DataModelHint( Customer.class );
    	
    	MemberHint memberHint = new MemberHint("firstName");
    	memberHint.setHint("Ed,Marty,Ralf,Ignacio,Andrei");
    	
    	MemberHint lastNameHint = new MemberHint("lastName");
    	lastNameHint.setHint("Pitt,Eustace,Bokelberg,Jurescu,Martin");
    	
    	dataHint.addMemberHint( memberHint );
    	dataHint.addMemberHint(lastNameHint);
    	
    	
    	ImplementorFactory factory = new ImplementorFactory( config );
    	factory.generateImplementorSource( CustomerService.class );
    	
    }
}
